Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow QuickTime movies to start with "skip" atom #90

Merged
merged 1 commit into from
Sep 3, 2023
Merged

Allow QuickTime movies to start with "skip" atom #90

merged 1 commit into from
Sep 3, 2023

Conversation

jangrudo
Copy link
Contributor

@jangrudo jangrudo commented Sep 3, 2023

I've got some *.mov files from a (rather old) Kodak EasyShare C533 camera, which have "skip" as the container's first atom, rather than "ftyp", "moov", or "free". They therefore don't pass the check in hachoir.parser.container.MP4File.validate(). This initial "skip" atom seems to contain some metadata like camera model name, and is followed by an "mdat" occupying most of the file, and then finally by a "moov".

I use hachoir to extract movie's duration and timestamp, and it works fine if validate() method is tweaked to allow "skip" as the initial atom. (Apparently, all the needed info is in "moov" at the end of the file).

Admittedly, "skip" doesn't look very characteristic of a movie file, but we already have "free" on the list, so it shouldn't make things much worse.

@vstinner
Copy link
Owner

vstinner commented Sep 3, 2023

The pep8 test was broken in the main branch. I fixed it. Can you please rebase your PR on the main branch to fix the CI?

@vstinner vstinner merged commit 38d759f into vstinner:main Sep 3, 2023
2 checks passed
@vstinner
Copy link
Owner

vstinner commented Sep 3, 2023

Tests pass, I'm happy, I merged your PR. Thanks for your contribution!

@jangrudo
Copy link
Contributor Author

jangrudo commented Sep 4, 2023

Thank you very much for the library!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants